Table 148 - WRITE SAME command
=============================================================================== | Bit| 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | |Byte | | | | | | | | | |=============================================================================| | 0 | Operation code (41h) | |-----------------------------------------------------------------------------| | 1 | Logical unit number | Reserved | PBdata | LBdata | RelAdr | |-----------------------------------------------------------------------------| | 2 | (MSB) | |--------- ---| | 3 | | |--------- Logical block address ---| | 4 | | |--------- ---| | 5 | (LSB) | |-----------------------------------------------------------------------------| | 6 | Reserved | |-----------------------------------------------------------------------------| | 7 | (MSB) | |--------- Number of blocks | | 8 | (LSB) | |-----------------------------------------------------------------------------| | 9 | Control | ===============================================================================( This command is useful if large areas of the medium need to be written, prepared for certification, or otherwise initialized without the initiator having to transfer all the data. )
A logical block data (LBdata) bit of one requests that the target replace the first four bytes of the data to be written to the current logical block with the logical block address of the block currently being written.
A physical block data (PBdata) bit of one requests that the target replace the first eight bytes of the data to be written to the current physical sector with the physical address of the sector currently being written using the physical sector format (see 9.2.1.1).
If PBdata and LBdata are one the command shall be terminated with CHECK CONDITION status. The sense key shall be set to ILLEGAL REQUEST.
See 9.2.2 for a definition of the RelAdr bit and the logical block address field.
The number of blocks field specifies the number of contiguous logical blocks to be written. A number of blocks field of zero requests that all the remaining logical blocks on the medium be written.